enum MarketDataTypes{ TodayOpen, YesterDayClose, High, Low, Last, Bid, Ask };
delegate void NewMarketDataDel(MarketDataTypes whatChanged, float price);

ref class MarketData
{
public:
	event NewMarketDataDel^ NewMarketData;

	float TodayOpen() { return todayOpen; }
	float YesterdayClose() { return yesterdayClose; }
	float High() { return high; }
	float Last() { return last; }
	float Ask() { return ask; }
	float Bid() { return bid; }

	void Start();
	void Start(TextBox ^textToUpdate);
	MarketData(Symbol ^owner);

protected:
	void getMarketData(System::Object ^sender, AxTWSLib::_DTwsEvents_tickPriceEvent ^e);

	Symbol ^owner;
	float todayOpen, yesterdayClose, high, low, last, ask, bid;
	int requestID;

	TextBox ^textToUpdate;
};